home *** CD-ROM | disk | FTP | other *** search
/ InfoMagic Internet Tools 1993 July / Internet Tools.iso / RockRidge / mail / sendmail / sendmail-5.65c+IDA-1.4.4.1 / support / flock.h < prev    next >
Encoding:
C/C++ Source or Header  |  1990-11-12  |  484 b   |  23 lines

  1. #ifndef _FLOCK_EMULATE_INCLUDED
  2. #define _FLOCK_EMULATE_INCLUDED
  3.  
  4. #include <fcntl.h>
  5.  
  6. #if defined(F_SETLK) && defined(F_SETLKW)
  7. # define FCNTL_FLOCK
  8. #else
  9. # define LOCKF_FLOCK
  10. #endif /* F_SETLK && F_SETLKW */
  11.  
  12. /* These definitions are in <sys/file.h> on BSD 4.3 */
  13.  
  14. /*
  15.  * Flock call.
  16.  */
  17. #define LOCK_SH        1    /* shared lock */
  18. #define LOCK_EX        2    /* exclusive lock */
  19. #define LOCK_NB        4    /* don't block when locking */
  20. #define LOCK_UN        8    /* unlock */
  21.  
  22. #endif /* _FLOCK_EMULATE_INCLUDED */
  23.